package online.longzipeng.mywebdemo.service.impl;

import lombok.extern.slf4j.Slf4j;
import online.longzipeng.mywebdemo.service.MyService;
import org.springframework.boot.autoconfigure.condition.ConditionalOnProperty;
import org.springframework.context.annotation.Primary;
import org.springframework.stereotype.Service;

/**
 * @Author: lzp
 * @description: 同一个service多个实现
 * @Date: 2023/2/26
 */
@Service("MyServiceA")
@Slf4j
@Primary
@ConditionalOnProperty(value = "my-service.active",havingValue = "A")
public class MyServiceAImpl implements MyService {


	@Override
	public void hello() {
		log.info("服务A 说你好帅啊~");
	}
}
